﻿<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="ProductAttributeEdit.ascx.cs"
    Inherits="HUGATE.Item.Controls.ProductAttribute.ProductAttributeEdit" %>
<%@ Register Src="ParentAttribute.ascx" TagName="ParentAttribute" TagPrefix="uc1" %>
<asp:UpdatePanel ID="udpEdit" runat="server" UpdateMode="Conditional">
    <ContentTemplate>
        <table border="0" cellpadding="2" cellspacing="0" style="width: 100%">
            <tr id="trID" runat="server">
                <td style="height: 28px; width: 200px">
                    <%=HUGATE.Utility.ResxManager.GetString("ID") + HUGATE.Utility.ResxManager.GetString("ITEMProductAttribute") + ":"%>
                </td>
                <td style="height: 28px;">
                    <asp:TextBox ID="txtObjectID" runat="server" ReadOnly="True" Style="width: 100px"
                        ValidationGroup="checkDataInput" MaxLength="8"></asp:TextBox>
                </td>
            </tr>
            <tr>
                <td>
                    <%=HUGATE.Utility.ResxManager.GetString("Name") + HUGATE.Utility.ResxManager.GetString("ITEMProductAttribute") + ":"%>
                </td>
                <td>
                    <asp:TextBox ID="txtObjectName" runat="server" MaxLength="200" ValidationGroup="checkDataInput"
                        Width="280px"></asp:TextBox>
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" ControlToValidate="txtObjectName"
                        ErrorMessage="*" ValidationGroup="checkDataInput"></asp:RequiredFieldValidator>
                </td>
            </tr>
            <tr>
                <td style="height: 106px">
                    <%=HUGATE.Utility.ResxManager.GetString("Description")+":" %>
                </td>
                <td valign="top" style="height: 106px">
                    <asp:TextBox ID="txtDesc" runat="server" Height="100px" TextMode="MultiLine" Width="280px"></asp:TextBox>
                </td>
            </tr>
            <tr>
                <td style="height: 23px">
                    <%=HUGATE.Utility.ResxManager.GetString("AttributeType") + ":"%>
                </td>
                <td style="height: 23px" align="left">
                    <asp:DropDownList ID="ddlAttributeType" runat="server" AutoPostBack="True" DataTextField="AttributeType"
                        DataValueField="AttributeType">
                        <asp:ListItem Value="0">Textbox (0)</asp:ListItem>
                        <asp:ListItem Value="1">Dropdownlist (1)</asp:ListItem>
                        <asp:ListItem Value="2">Listbox(2)</asp:ListItem>
                    </asp:DropDownList>
                </td>
            </tr>
            <tr>
                <td style="height: 23px" align="left">
                    <%=HUGATE.Utility.ResxManager.GetString("Actived") %>
                </td>
                <td>
                    <asp:CheckBox ID="chkIsActived" runat="server" AutoPostBack="True" OnCheckedChanged="chkIsActived_CheckedChanged" />
                </td>
            </tr>
            <tr>
                <td>
                    <%=HUGATE.Utility.ResxManager.GetString("OfParentAttributeID") + ":"%>
                </td>
                <td>
                    <asp:UpdatePanel ID="Upnsel" runat="server" UpdateMode="Conditional">
                        <ContentTemplate>
                            <asp:TextBox ID="txtparentAttributeID" runat="server" ReadOnly="True" Width="148px" />
                            <asp:ImageButton ID="imgsel" runat="server" ImageUrl="~/App_Themes/Default/Images/Buttons/bnt_Select.GIF"
                                OnClick="imgsel_Click1" ToolTip="Click vào để chọn Thuộc Tính" />
                            <asp:Panel ID="pnsel" runat="server" CssClass="Popup_Table" Style="display: none;
                                width: 450px">
                                <div class="Popup_Title">
                                    <table border="0" cellpadding="0" cellspacing="0" class="Popup_Title" style="width: 100%">
                                        <tbody>
                                            <tr>
                                                <td>
                                                    <strong>
                                                        <asp:Label ID="lblTitle2" runat="server"></asp:Label>
                                                    </strong>
                                                </td>
                                                <td align="center" style="padding-right: 2px; width: 20px">
                                                    <div class="Popup_BtClose" style="width: 17px; height: 17px; text-align: center">
                                                        <asp:LinkButton ID="lnkClose" runat="server" CssClass="Popup_BtClose" Height="17px"
                                                            Width="17px">&nbsp;&nbsp;&nbsp;&nbsp;</asp:LinkButton>
                                                    </div>
                                                </td>
                                            </tr>
                                        </tbody>
                                    </table>
                                </div>
                                <div runat="server" class="Popup_Content">
                                    <div style="width:300px;height:500px;overflow-y: scroll;">
                                        <uc1:ParentAttribute ID="CtrlParentAttribute" runat="server" />
                                    </div>
                                </div>
                                <div id="divcontrol" runat="server">
                                </div>
                                <ajax:ModalPopupExtender ID="mpesel" runat="server" BackgroundCssClass="ModalPopupBackground"
                                    PopupControlID="pnsel" TargetControlID="divcontrol">
                                </ajax:ModalPopupExtender>
                            </asp:Panel>
                        </ContentTemplate>
                    </asp:UpdatePanel>
                </td>
                <tr>
                    <td style="height: 28px">
                    </td>
                    <td style="height: 28px">
                        <asp:Button ID="btnUpdate" runat="server" CssClass="Control_Button1" OnClick="btnUpdate_Click"
                            ValidationGroup="checkDataInput" />
                        <asp:Button ID="btnCancel" runat="server" CssClass="Control_Button1" OnClick="btnCancel_Click" />
                    </td>
                </tr>
            </tr>
        </table>
    </ContentTemplate>
</asp:UpdatePanel>
